package com.neusoft.yuejian12.yuejian_12.base;

import retrofit2.Call;
import retrofit2.Callback;
import retrofit2.Response;

public abstract class RetrofitCallback<T> implements Callback {

    abstract public void onResponse(T t);

    @Override
    public void onResponse(Call call, Response response) {
        onResponse((T)response.body());
    }

    @Override
    public void onFailure(Call call, Throwable t){
        System.err.println("error");
    }
}
